package com.dianqiu.common.bean;

import java.sql.Timestamp;
import javax.persistence.AttributeOverride;
import javax.persistence.AttributeOverrides;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.dianqiu.base.bean.BaseTO;

/**
 * DqClubPlayers entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "dq_club_players", catalog = "dq_dev")
public class DqClubPlayersTO  extends BaseTO implements java.io.Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private DqClubPlayersIdTO id;
	private DqClubsTO dqClubs;
	private DqPlayersTO dqPlayers;
	private Timestamp jointDt;

	@EmbeddedId
	@AttributeOverrides( {
			@AttributeOverride(name = "clbId", column = @Column(name = "CLB_ID", nullable = false)),
			@AttributeOverride(name = "plyrId", column = @Column(name = "PLYR_ID", nullable = false)) })
	public DqClubPlayersIdTO getId() {
		return id;
	}

	public void setId(DqClubPlayersIdTO id) {
		this.id = id;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "CLB_ID", nullable = false, insertable = false, updatable = false)
	public DqClubsTO getDqClubs() {
		return this.dqClubs;
	}

	public void setDqClubs(DqClubsTO dqClubs) {
		this.dqClubs = dqClubs;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "PLYR_ID", nullable = false, insertable = false, updatable = false)
	public DqPlayersTO getDqPlayers() {
		return this.dqPlayers;
	}

	public void setDqPlayers(DqPlayersTO dqPlayers) {
		this.dqPlayers = dqPlayers;
	}

	@Column(name = "JOINT_DT", length = 19)
	public Timestamp getJointDt() {
		return this.jointDt;
	}

	public void setJointDt(Timestamp jointDt) {
		this.jointDt = jointDt;
	}

	
}